#include <iostream>
using namespace std;
int main(){
    char number[100];
    cin>>number;
    char a=number[0];
    int count=0;
    int num=0;
    while (a!='\0'){
        num=10*num+(a-'0');
        count++;
        a=number[count];
    }
    cout<<num<<endl;
    return 0;
}